<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
<%@taglib uri="/WEB-INF/struts-logic.tld" prefix="logic"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<base href="<%=basePath%>">

		<title>My JSP 'userSelfInfo.jsp' starting page</title>

		<meta http-equiv="pragma" content="no-cache">
		<meta http-equiv="cache-control" content="no-cache">
		<meta http-equiv="expires" content="0">
		<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
		<meta http-equiv="description" content="This is my page">
		<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
	</head>
	<body>
		<div id="userInfo">
			<html:form action="userAction.do" method="post">
				<fieldset>
					<legend>
						用户信息
					</legend>
					<table border="0" width="100%">
						<tr>
							<td width="30%">
								用户名：
							</td>
							<td align="left">
								${userInfo.userName}
							</td>
						</tr>
						<tr>
							<td>
								用户真实姓名：
							</td>
							<td>
								${userInfo.userRealName}
							</td>
						</tr>
						<tr>
							<td>
								用戶密码：
							</td>
							<td>
								${userInfo.userPwd}
							</td>
						</tr>
						<tr>
							<td>
								用户邮箱：
							</td>
							<td>
								${userInfo.userEmail}
							</td>
						</tr>
						<tr>
							<td>
								用户电话：
							</td>
							<td>
								${userInfo.userTelephone}
							</td>
						</tr>
						<tr>
							<td>
								<html:hidden property="userID" value="${userInfo.userID}"/>
							</td>
							<td>							
								<html:button property="toUpdateUser"
									onclick="submitForm('toUpdateUser');" value="修改信息" />
								<html:reset value="button占位" />
								<script>
	function submitForm(operation) {
		with (document.forms[0]) {
			action = action + "?method=" + operation;
			submit();
		}
	}
</script>
							</td>
						</tr>
					</table>
				</fieldset>
			</html:form>
		</div>
	</body>
</html>